import java.util.Scanner;

public class zuoye3 {
        //    编写函数，计算圆的面积和周长，在主函数中接受圆的半径，在自定义函数中计算并输出
        public static void main(String[] args) {
            Scanner bj = new Scanner(System.in);
            System.out.println("请输入圆的半径(cm):");
            double num = bj.nextInt();
            double s = qq(num);
            System.out.println("圆的面积为:" + s+"(cm)");
            double l = ww(num);
            System.out.println("圆的周长为:" + l+"(cm)");
        }
        static double qq(double num) {
            return (num * num) * 3.14;
        }
        static double ww(double num) {
            return 2 * 3.14 * num;
        }
    }

